#include "Protocol_EP.h"

CProtocol_EP::CProtocol_EP(void)
{
	name = "EP";
}

CProtocol_EP::~CProtocol_EP(void)
{
}

StackUtils::e_Status CProtocol_EP::Decode( CPacket& packet )
{
	packet.removeElements(0, name.size() + 2);
	packet.removeElements(packet.getBufferContent().size() - (name.size() + 2), name.size() + 2);
	return StackUtils::E_SUCCESS;
}

StackUtils::e_Status CProtocol_EP::Encode( CPacket& packet )
{
	packet.addFront("[EP]");
	packet.addBack("[EP]");

	return StackUtils::E_SUCCESS;
}
